3.14.21 \(\int \frac {(c (d \tan (e+f x))^p)^n}{a+i a \tan (e+f x)} \, dx\) [1321]

Optimal. Leaf size=134 \[ \frac {\, _2F_1\left (2,\frac {1}{2} (1+n p);\frac {1}{2} (3+n p);-\tan ^2(e+f x)\right ) \tan (e+f x) \left (c (d \tan (e+f x))^p\right )^n}{a f (1+n p)}-\frac {i \, _2F_1\left (2,\frac {1}{2} (2+n p);\frac {1}{2} (4+n p);-\tan ^2(e+f x)\right ) \tan ^2(e+f x) \left (c (d \tan (e+f x))^p\right )^n}{a f (2+n p)} \]

[Out]

hypergeom([2, 1/2*n*p+1/2],[1/2*n*p+3/2],-tan(f*x+e)^2)*tan(f*x+e)*(c*(d*tan(f*x+e))^p)^n/a/f/(n*p+1)-I*hyperg
eom([2, 1/2*n*p+1],[1/2*n*p+2],-tan(f*x+e)^2)*tan(f*x+e)^2*(c*(d*tan(f*x+e))^p)^n/a/f/(n*p+2)

________________________________________________________________________________________

Rubi [A]
time = 0.15, antiderivative size = 134, normalized size of antiderivative = 1.00, number of steps used = 8, number of rules used = 5, integrand size = 30, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {1970, 862, 83, 74, 371} \begin {gather*} \frac {\tan (e+f x) \, _2F_1\left (2,\frac {1}{2} (n p+1);\frac {1}{2} (n p+3);-\tan ^2(e+f x)\right ) \left (c (d \tan (e+f x))^p\right )^n}{a f (n p+1)}-\frac {i \tan ^2(e+f x) \, _2F_1\left (2,\frac {1}{2} (n p+2);\frac {1}{2} (n p+4);-\tan ^2(e+f x)\right ) \left (c (d \tan (e+f x))^p\right )^n}{a f (n p+2)} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(c*(d*Tan[e + f*x])^p)^n/(a + I*a*Tan[e + f*x]),x]

[Out]

(Hypergeometric2F1[2, (1 + n*p)/2, (3 + n*p)/2, -Tan[e + f*x]^2]*Tan[e + f*x]*(c*(d*Tan[e + f*x])^p)^n)/(a*f*(
1 + n*p)) - (I*Hypergeometric2F1[2, (2 + n*p)/2, (4 + n*p)/2, -Tan[e + f*x]^2]*Tan[e + f*x]^2*(c*(d*Tan[e + f*
x])^p)^n)/(a*f*(2 + n*p))

Rule 74

Int[((a_) + (b_.)*(x_))^(m_.)*((c_) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> Int[(a*c + b*
d*x^2)^m*(e + f*x)^p, x] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && EqQ[b*c + a*d, 0] && EqQ[n, m] && Integer
Q[m] && (NeQ[m, -1] || (EqQ[e, 0] && (EqQ[p, 1] ||  !IntegerQ[p])))

Rule 83

Int[((f_.)*(x_))^(p_.)*((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Dist[a, Int[(a + b*
x)^n*(c + d*x)^n*(f*x)^p, x], x] + Dist[b/f, Int[(a + b*x)^n*(c + d*x)^n*(f*x)^(p + 1), x], x] /; FreeQ[{a, b,
 c, d, f, m, n, p}, x] && EqQ[b*c + a*d, 0] && EqQ[m - n - 1, 0] &&  !RationalQ[p] &&  !IGtQ[m, 0] && NeQ[m +
n + p + 2, 0]

Rule 371

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[a^p*((c*x)^(m + 1)/(c*(m + 1)))*Hyperg
eometric2F1[-p, (m + 1)/n, (m + 1)/n + 1, (-b)*(x^n/a)], x] /; FreeQ[{a, b, c, m, n, p}, x] &&  !IGtQ[p, 0] &&
 (ILtQ[p, 0] || GtQ[a, 0])

Rule 862

Int[((d_) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))^(n_)*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[(d + e*x)
^(m + p)*(f + g*x)^n*(a/d + (c/e)*x)^p, x] /; FreeQ[{a, c, d, e, f, g, m, n}, x] && NeQ[e*f - d*g, 0] && EqQ[c
*d^2 + a*e^2, 0] && (IntegerQ[p] || (GtQ[a, 0] && GtQ[d, 0] && EqQ[m + p, 0]))

Rule 1970

Int[(u_.)*((c_.)*((d_)*((a_.) + (b_.)*(x_)))^(q_))^(p_), x_Symbol] :> Dist[(c*(d*(a + b*x))^q)^p/(a + b*x)^(p*
q), Int[u*(a + b*x)^(p*q), x], x] /; FreeQ[{a, b, c, d, q, p}, x] &&  !IntegerQ[q] &&  !IntegerQ[p]

Rubi steps

\begin {align*} \int \frac {\left (c (d \tan (e+f x))^p\right )^n}{a+i a \tan (e+f x)} \, dx &=\frac {\text {Subst}\left (\int \frac {\left (c (d x)^p\right )^n}{(a+i a x) \left (1+x^2\right )} \, dx,x,\tan (e+f x)\right )}{f}\\ &=\frac {\left ((d \tan (e+f x))^{-n p} \left (c (d \tan (e+f x))^p\right )^n\right ) \text {Subst}\left (\int \frac {(d x)^{n p}}{(a+i a x) \left (1+x^2\right )} \, dx,x,\tan (e+f x)\right )}{f}\\ &=\frac {\left ((d \tan (e+f x))^{-n p} \left (c (d \tan (e+f x))^p\right )^n\right ) \text {Subst}\left (\int \frac {(d x)^{n p}}{\left (\frac {1}{a}-\frac {i x}{a}\right ) (a+i a x)^2} \, dx,x,\tan (e+f x)\right )}{f}\\ &=\frac {\left ((d \tan (e+f x))^{-n p} \left (c (d \tan (e+f x))^p\right )^n\right ) \text {Subst}\left (\int \frac {(d x)^{n p}}{\left (\frac {1}{a}-\frac {i x}{a}\right )^2 (a+i a x)^2} \, dx,x,\tan (e+f x)\right )}{a f}-\frac {\left (i (d \tan (e+f x))^{-n p} \left (c (d \tan (e+f x))^p\right )^n\right ) \text {Subst}\left (\int \frac {(d x)^{1+n p}}{\left (\frac {1}{a}-\frac {i x}{a}\right )^2 (a+i a x)^2} \, dx,x,\tan (e+f x)\right )}{a d f}\\ &=\frac {\left ((d \tan (e+f x))^{-n p} \left (c (d \tan (e+f x))^p\right )^n\right ) \text {Subst}\left (\int \frac {(d x)^{n p}}{\left (1+x^2\right )^2} \, dx,x,\tan (e+f x)\right )}{a f}-\frac {\left (i (d \tan (e+f x))^{-n p} \left (c (d \tan (e+f x))^p\right )^n\right ) \text {Subst}\left (\int \frac {(d x)^{1+n p}}{\left (1+x^2\right )^2} \, dx,x,\tan (e+f x)\right )}{a d f}\\ &=\frac {\, _2F_1\left (2,\frac {1}{2} (1+n p);\frac {1}{2} (3+n p);-\tan ^2(e+f x)\right ) \tan (e+f x) \left (c (d \tan (e+f x))^p\right )^n}{a f (1+n p)}-\frac {i \, _2F_1\left (2,\frac {1}{2} (2+n p);\frac {1}{2} (4+n p);-\tan ^2(e+f x)\right ) \tan ^2(e+f x) \left (c (d \tan (e+f x))^p\right )^n}{a f (2+n p)}\\ \end {align*}

________________________________________________________________________________________

Mathematica [F]
time = 18.97, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\left (c (d \tan (e+f x))^p\right )^n}{a+i a \tan (e+f x)} \, dx \end {gather*}

Verification is not applicable to the result.

[In]

Integrate[(c*(d*Tan[e + f*x])^p)^n/(a + I*a*Tan[e + f*x]),x]

[Out]

Integrate[(c*(d*Tan[e + f*x])^p)^n/(a + I*a*Tan[e + f*x]), x]

________________________________________________________________________________________

Maple [F]
time = 0.19, size = 0, normalized size = 0.00 \[\int \frac {\left (c \left (d \tan \left (f x +e \right )\right )^{p}\right )^{n}}{a +i a \tan \left (f x +e \right )}\, dx\]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((c*(d*tan(f*x+e))^p)^n/(a+I*a*tan(f*x+e)),x)

[Out]

int((c*(d*tan(f*x+e))^p)^n/(a+I*a*tan(f*x+e)),x)

________________________________________________________________________________________

Maxima [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: RuntimeError} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*(d*tan(f*x+e))^p)^n/(a+I*a*tan(f*x+e)),x, algorithm="maxima")

[Out]

Exception raised: RuntimeError >> ECL says: THROW: The catch RAT-ERR is undefined.

________________________________________________________________________________________

Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*(d*tan(f*x+e))^p)^n/(a+I*a*tan(f*x+e)),x, algorithm="fricas")

[Out]

integral(1/2*(e^(2*I*f*x + 2*I*e) + 1)*e^(n*p*log((-I*d*e^(2*I*f*x + 2*I*e) + I*d)/(e^(2*I*f*x + 2*I*e) + 1))
- 2*I*f*x + n*log(c) - 2*I*e)/a, x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - \frac {i \int \frac {\left (c \left (d \tan {\left (e + f x \right )}\right )^{p}\right )^{n}}{\tan {\left (e + f x \right )} - i}\, dx}{a} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*(d*tan(f*x+e))**p)**n/(a+I*a*tan(f*x+e)),x)

[Out]

-I*Integral((c*(d*tan(e + f*x))**p)**n/(tan(e + f*x) - I), x)/a

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*(d*tan(f*x+e))^p)^n/(a+I*a*tan(f*x+e)),x, algorithm="giac")

[Out]

integrate(((d*tan(f*x + e))^p*c)^n/(I*a*tan(f*x + e) + a), x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (c\,{\left (d\,\mathrm {tan}\left (e+f\,x\right )\right )}^p\right )}^n}{a+a\,\mathrm {tan}\left (e+f\,x\right )\,1{}\mathrm {i}} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((c*(d*tan(e + f*x))^p)^n/(a + a*tan(e + f*x)*1i),x)

[Out]

int((c*(d*tan(e + f*x))^p)^n/(a + a*tan(e + f*x)*1i), x)

________________________________________________________________________________________